package com.trsj.lnsj.model;

import org.apache.ibatis.jdbc.SQL;
import org.springframework.util.StringUtils;

public class UserProvider {
  private final String USER = "user";

  public String queryUserByParam(String name) {
    SQL sql = new SQL().SELECT("*").FROM(USER);
    // String name = param.getName();
    if (StringUtils.isEmpty(name)) {
      sql.WHERE("name = #{name}");
    }
    return sql.toString();
  }
}
